/*
 * CS_EVOLUTION_POINT_CHARGE.cpp
 *
 *  Created on: 2013. 6. 19.
 *      Author: mega@gamevil.com
 */

#include "../../Command.h"
#include "../../User.h"

namespace ProjectZ { namespace NCommand {

void Command::CS_EVOLUTION_POINT_CHARGE(User * pUser, ::Network::Packet * pPacket)
{

//	PREPARE_PACKET;
//	//Player_Info &player_info = pUser->player_info;
//
//	uint16_t add_point	= 0;
//
//	pPacket->ParseMsg("%2d", &add_point);
//
//	FILELOG("[CS_EVOLUTION_POINT_CHARGE] GID=%d, user_seq=%d, add_point=%d",
//			pUser->GetGID(), pUser->GetUserSeq(), add_point);
//
//	ProjectZ::CDBHelper db(pUser, ::Database::Command::__NONE__);
//
//	// 유저의 진화 포인트 증감
//	pUser->GetCharacterInfo().ep_current += add_point;
//	if (pUser->GetCharacterInfo().ep_current > pUser->GetCharacterInfo().ep_max) {
//		pUser->GetCharacterInfo().ep_current = pUser->GetCharacterInfo().ep_max;
//	}
//
//	// 유저의 진화 포인트 갱신
//	DataContainer->GetCPoint()->UpdateEvolvePoint(pUser, db);
//
//
//	FILELOG("[CS_EVOLUTION_POINT_CHARGE] user_seq=%d, ep_current=%d, ep_max=%d",
//			pUser->GetUserSeq(), pUser->GetCharacterInfo().ep_current, pUser->GetCharacterInfo().ep_max);
//
//	// 응답
//	SendPacket(pUser, ACK_OK, add_point);
}


//void
//CS_EVOLUTION_POINT_CHARGE::SendPacket(User * pUser, const int res,
//		const int point) {
//
//	::Network::Packet * pAck = ::Network::GETPACKETPOOL()->SEND_NEW();
//
//	pAck->MsgCat("%2d", res);
//	pAck->MsgCat("%2d", point);
//	pAck->MakePacket(CMD_SC_EVOLUTION_POINT_CHARGE);
//
//	pUser->Send(pAck);
//}

} /*NCommand*/ } /*ProjectZ*/
